MainCamera

Main camera interface for Anafi2 drones.

Provides access to a drone's main (usually front) camera, if available.

The main camera can be obtained from a Drone using: drone.getPeripheral(MainCamera::class.java)

See also

Drone.getPeripheral

Properties

Link copied to clipboard
abstract val active: Boolean

Returns true when this camera is active, false otherwise

Link copied to clipboard
abstract val config: Camera.Config

Returns this camera current configuration.

Functions

Link copied to clipboard
abstract fun <C : Camera.Component> component(componentClass: Class<C>): C?

Provides access to a camera component.

abstract fun <C : Camera.Component> component(componentClass: Class<C>, observer: Ref.Observer<C>): Ref<C>

Allows to observe a camera component.

Link copied to clipboard
inline fun <C : Camera.Component> Camera.component(): C?

Provides access to a camera component.

inline fun <C : Camera.Component> Camera.component(crossinline observer: (C?) -> Unit): Ref<C>

Allows to observe a camera component.